package Binary;

public class CompelementDemo {
    public static void main(String[] args) {
        int i = -45;
        System.out.println(Integer.toBinaryString(i));
        System.out.println(45);

        int o = 499999999;
        System.out.println(Integer.toBinaryString(o));
        System.out.println(Integer.toHexString(o));





        /*
        int max = Integer.MAX_VALUE;
        int min = Integer.MIN_VALUE;
        System.out.println(Integer.toBinaryString(max)); //最大值
        System.out.println(Integer.toBinaryString(min)); //最小值
        System.out.println(Integer.toBinaryString(-1)); //第一位负数
        System.out.println(Integer.toBinaryString(-11111111));
         */
    }
}
